﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ErrorLog.aspx.cs" Inherits="ErrorLog" %>
<%@ Register Src="head.ascx" TagName="Head" TagPrefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>错误日志列表</title>
    <link href="StyleSheet.css" rel="stylesheet" type="text/css" />
</head>
<body>
 <div style="vertical-align: middle; text-align: center">
    <form id="form1" runat="server">
        <table width="100%" border="0">
        <tr>
          <td>
          <uc1:Head ID="Head2" runat="server" />
         </td>
       </tr>
       <tr>
         <td style="font-size: 15px; font-family: 宋体;">
           <br />
           <br />
           错误日志 <br />
           <br />&nbsp;
           
           Domain:<asp:DropDownList AutoPostBack="true" ID="DDLDomain" runat="server" DataTextField="Domain" DataValueField="DomainID" OnSelectedIndexChanged="DDLDomain_SelectedIndexChanged"></asp:DropDownList> &nbsp;URL:<asp:DropDownList ID="DDLUrl" runat="server" DataTextField="SendMessage" DataValueField="UrlID" OnDataBound="DDLUrl_DataBound"></asp:DropDownList>
           <asp:Button ID="cmdSearch" AutoPostBack="true" runat="server" OnClick="cmdSearch_Click" Text="查询" />
             &nbsp;&nbsp;
             <a href="ErrorDay.aspx">按天统计</a><br />
           
           <asp:GridView PagerSettings-Mode="Numeric" ID="GridView1" runat="server" AllowPaging="True" AutoGenerateColumns="False" CaptionAlign="Top" OnPageIndexChanging="GridView1_PageIndexChanging" PageSize="40" >
            <Columns>
                <asp:HyperLinkField DataNavigateUrlFields="ErrorLogID" DataNavigateUrlFormatString="ErrorLogDetail.aspx?ErrorLogId={0}"
                    DataTextField="ErrorLogID" HeaderText="ID" />
                <asp:TemplateField HeaderText="标题">
                  <ItemTemplate>
                     <a href='<%# GetLink(Convert.ToInt32(DataBinder.Eval(Container.DataItem, "ErrorLogID")))%>' target="_blank"><%# GetSendMessage(Convert.ToInt32(DataBinder.Eval(Container.DataItem, "ErrorLogID")))%></a>
                  </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="域">
                   <ItemTemplate>
                    <%# GetDomain(Convert.ToInt32(DataBinder.Eval(Container.DataItem, "ErrorLogID")))%>
                  </ItemTemplate>
                </asp:TemplateField>
                <asp:BoundField DataField="Content" HeaderText="内容" />
                <asp:BoundField DataField="Checkintime" HeaderText="时间" />
                <asp:HyperLinkField DataNavigateUrlFields="ErrorLogID" DataNavigateUrlFormatString="Download.aspx?ErrorLogID={0}"
                    HeaderText="下载出错文件" Text="下载" />
            </Columns>
        </asp:GridView>
        </td>
        </tr>
        </table>
        <br />
    </form>
    </div>
</body>
</html>
